<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
</head>
<LINK href="../../css/admin.css" type="text/css" rel="stylesheet">
<script src="../../js/jquery.js"></script>
<script src="../../js/changebgcolor.js"></script>
<script src="../../js/calendar.js"></script>
<script>

//onclick="alert(this.offsetWidth)"
function showDiv(obj){
	obj.style.display = "";
}

function bgcolorTo(obj,to_color){
	obj.style.background = to_color;
}
// 界面控制 begin 
function show_message(){
	var mask = document.getElementById("mask");
	var message = document.getElementById("message");
	var sel1_obj = document.getElementById("sel1");
	var sel2_obj = document.getElementById("sel2");	
	mask.style.display = "";
	message.style.display = "";
	sel1_obj.style.display = "none";
	sel2_obj.style.display = "none";
}
function hidden_message(){
	var mask = document.getElementById("mask");
	var message = document.getElementById("message");
	var sel1_obj = document.getElementById("sel1");
	var sel2_obj = document.getElementById("sel2");	
	mask.style.display = "none";
	message.style.display = "none";
	sel1_obj.style.display = "";
	sel2_obj.style.display = "";
}
// 界面控制 end 

// 创建新课程功能按钮，用于界面控制
function create(){
	show_message();
	document.getElementById("mesg").reset();
		
	var btn_update = document.getElementById("update");
	var btn_create = document.getElementById("create");
	
	btn_update.style.display = "none";
	btn_create.style.display = "";
	
}
// 创建功能按钮，用于后台交互
function create_class(){
	hidden_message();
	
	//Jquery 代码
	
}


// 查看功能按钮，用来界面控制和后台交互
function select_class_id(id){
	show_message();
	
	var btn_update = document.getElementById("update");
	var btn_create = document.getElementById("create");
	
	btn_update.style.display = "";
	btn_create.style.display = "none";
	
	//Jquery 代码
	
}
// 编辑功能按钮，用来界面控制
function update(){
	//将 div_message 中的 组件设置成可编辑
	
}
// 保存功能按钮，用来后台交互
function update_class(id){
	hidden_message();
	//Jquery 代码
	
}
// 查询按钮，用来后台交互
function select_class(id){
	hidden_message();
	//Jquery 代码
	
}
// 查询按钮，用来后台交互
function create_teacher(obj){
	var man_num = obj.value;
	var str_html = "";
	for(var i = 0 ; i<man_num ; i++ ){
		str_html = str_html + '<input id="ter'+ i +'" type="text" style="border:0; width:52px;" class="input_news" value="培训方'+ i +'"/><br />';
	}
	var ters = document.getElementById("ters");
	ters.innerHTML = str_html;
}

window.onload = function (){
	var now_time = new Date();
	var curr_month = now_time.getMonth() + 1;
	if(curr_month < 10){
		curr_month = '0' + curr_month;
	}else{
		curr_month = curr_month - 12;
	}
	document.getElementById('plan_mounth').value = curr_month;
}
/*
function super_find(id){
	var str_html = '课程名<input id="class_name" type="text" style="width:410px;"/>&nbsp;|&nbsp;'
				+ '举办单位<input id="class_company" type="text" style="width:240px;"/><br/>'
				+ '开班日期<input id="start_time" type="text" />&nbsp;|&nbsp;'
				+ '结束日期<input id="end_time" type="text"/>&nbsp;|&nbsp;'
				+ '<a href="#" onclick="showDiv(super_find)">培训班查找</a>';
	var obj = $('#'+id);
	obj.html(str_html);
}
*/
</script>

<BODY>
<div id="div_header" >
  <div id="div_titel">制定办班计划</div>
</div>
<!-- 页面主体显示培训班列表 -->
<div id="div_body">
  <div align="center" style="padding-bottom:5px;"> 培训班名
    <input id="class_name" type="text" style="width:170px;"/>
    &nbsp;举办单位
    <input id="class_company" type="text" style="width:110px;"/>
    &nbsp;承办部门
    <select id="sel1">
      <option value="-1"></option>
      <option>培训管理部</option>
      <option>党校办公室</option>
    </select>
    &nbsp;状态
    <select id="sel2">
      <option value="-1"></option>
      <option>开班</option>
      <option>未开班</option>
    </select>
    &nbsp;月份
    <input id="plan_mounth" type="text" style="width:20px;" value="" />
    &nbsp; <a href="#" onclick="alert('selectClass')">查找</a> </div>
  <table class="list" style="width:100%;">
    <thead class="list">
      <tr class="list" height="10" >
        <th class="list" width="170" >举办单位</th>
        <th class="list" width="" >培训班</th>
        <th class="list" width="80" >承办部门</th>
        <th class="list" width="80" >开班日期</th>
        <th class="list" width="80" >结束日期</th>
        <th class="list" width="50" >状态</th>
        <th class="list" width="80" ><a href="#" onclick="create()">添加计划</a></th>
      </tr>
    </thead>
    <tbody class="list">
      <tr class="list">
        <td class="list" colspan="7" style="padding:0;"><div style="height:480px; overflow-y:scroll;">
            <table class="list" onmouseover="changeto()" onmouseout="changeback()" width="821"
    style="border-collapse:collapse; border-spacing:0; border:0px solid #888; background:#efefef;" >
              <tr class="list">
                <td class="list" width="170">&nbsp;行内蒙古区鄂尔多斯分行</td>
                <td class="list" width="">&nbsp;总行2010年市场风险管理培训班</td>
                <td class="list" width="80" align="center">培训管理部</td>
                <td class="list" width="80" align="center">2010.12.12</td>
                <td class="list" width="80" align="center">2010.12.12</td>
                <td class="list" width="50" align="center">开班</td>
                <td class="list" width="62" align="center"><a href="#" onclick="select_class_id('+id+')">编辑</a>&nbsp;<a href="#" onclick="alert('deleteById')">删除</a></td>
              </tr>
            </table>
          </div></td>
      </tr>
    </tbody>
  </table>
</div>
<!-- 遮罩层 -->
<div id="mask" style="display:none;"></div>
<!-- 培训班基础信息 -->
<div id="message" class="message" style="display:none; width:500px; margin-left:-250px; top:100px; ">
  <div style="position:absolute; width:30px; top:0; right:0;">
    <input type="button" style="width:100%; border:0; background-color:#C00;" onmouseover="bgcolorTo(this,'#f00')" onmouseout="bgcolorTo(this,'#C00')" 
  value=" X " onclick="hidden_message()" />
  </div>
  <br />
  <form id="mesg" action="#" style="padding:0; margin:0;">
    <table class="list" width="100%"
    style="border-collapse:collapse; border-spacing:0; border:1px solid #888; background:#efefef; " >
      <tr>
        <th class="list" width="100" >项目类别</th>
        <td class="list" style="background-color:#FFF">
          <input type="radio" name="is_zh" checked="checked"/>总行
          <input type="radio" name="is_zh" />分行
          <input type="radio" name="timeout" checked="checked"/>长期项目
          <input type="radio" name="timeout" />短期项目
        </td>
      </tr>
      <tr class="list">
        <th class="list" align="left" width="100" >举办单位</th>
        <td class="list" style="background-color:#FFF"><input class="msg_class" /></td>
      </tr>
      <tr class="list">
        <th class="list" align="left" width="100" >承办部门</th>
        <td class="list" style="background-color:#FFF"><select style="width:100%">
            <option>培训管理部</option>
            <option>党校办公室</option>
          </select></td>
      </tr>
      <tr class="list">
        <th class="list" align="left" width="100">培训班名称</th>
        <td class="list" style="background-color:#FFF"><input class="msg_class"/></td>
      </tr>
      <tr class="list">
        <th class="list" align="left" width="100">培训人数</th>
        <td class="list" style="background-color:#FFF"><input class="msg_class"/></td>
      </tr>
      <tr class="list" >
        <th class="list" width="100">开班日期</th>
        <td class="list" style="background-color:#FFF"><input class="msg_class" readonly="readonly" onfocus="calendar.setHook(this);" /></td>
      </tr>
      <tr class="list" >
        <th class="list" width="100" >结束日期</th>
        <td class="list" style="background-color:#FFF"><input class="msg_class" readonly="readonly" onfocus="calendar.setHook(this);" /></td>
      </tr>
      <tr class="list" >
        <th class="list" width="100" >培训天数</th>
        <td class="list" style="background-color:#FFF"><input class="msg_class" /></td>
      </tr>
      <tr>
        <th class="list" width="100" >是否计划内</th>
        <td class="list" style="background-color:#FFF">
          <input type="radio" name="is_out" checked="checked"/>
          是
          <input type="radio" name="is_out"/>
          否 </td>
      </tr>
      <tr>
        <th class="list" width="100" >相关说明</th>
        <td class="list" style="background-color:#FFF"><textarea class="msg_class" style="height:60px;"></textarea></td>
      </tr>
    </table>
    <table width="100%">
      <tr>
        <td align="right"><input type="button" id="update" value="保存" onclick="update_class()" />
          <input type="button" id="create" value="创建" onclick="create_class()" /></td>
      </tr>
    </table>
  </form>
</div>
</body>
</html>
